3.91 \(\int (a+a \sin (e+f x))^2 (A+B \sin (e+f x)) (c-c \sin (e+f x))^{3/2} \, dx\)

Optimal. Leaf size=120 \[ \frac{2 a^2 c^3 (9 A+B) \cos ^5(e+f x)}{63 f (c-c \sin (e+f x))^{3/2}}+\frac{8 a^2 c^4 (9 A+B) \cos ^5(e+f x)}{315 f (c-c \sin (e+f x))^{5/2}}-\frac{2 a^2 B c^2 \cos ^5(e+f x)}{9 f \sqrt{c-c \sin (e+f x)}} \]

[Out]

(8*a^2*(9*A + B)*c^4*Cos[e + f*x]^5)/(315*f*(c - c*Sin[e + f*x])^(5/2)) + (2*a^2*(9*A + B)*c^3*Cos[e + f*x]^5)
/(63*f*(c - c*Sin[e + f*x])^(3/2)) - (2*a^2*B*c^2*Cos[e + f*x]^5)/(9*f*Sqrt[c - c*Sin[e + f*x]])

________________________________________________________________________________________

Rubi [A]  time = 0.386664, antiderivative size = 120, normalized size of antiderivative = 1., number of steps used = 4, number of rules used = 4, integrand size = 38, \(\frac{\text{number of rules}}{\text{integrand size}}\) = 0.105, Rules used = {2967, 2856, 2674, 2673} \[ \frac{2 a^2 c^3 (9 A+B) \cos ^5(e+f x)}{63 f (c-c \sin (e+f x))^{3/2}}+\frac{8 a^2 c^4 (9 A+B) \cos ^5(e+f x)}{315 f (c-c \sin (e+f x))^{5/2}}-\frac{2 a^2 B c^2 \cos ^5(e+f x)}{9 f \sqrt{c-c \sin (e+f x)}} \]

Antiderivative was successfully verified.

[In]

Int[(a + a*Sin[e + f*x])^2*(A + B*Sin[e + f*x])*(c - c*Sin[e + f*x])^(3/2),x]

[Out]

(8*a^2*(9*A + B)*c^4*Cos[e + f*x]^5)/(315*f*(c - c*Sin[e + f*x])^(5/2)) + (2*a^2*(9*A + B)*c^3*Cos[e + f*x]^5)
/(63*f*(c - c*Sin[e + f*x])^(3/2)) - (2*a^2*B*c^2*Cos[e + f*x]^5)/(9*f*Sqrt[c - c*Sin[e + f*x]])

Rule 2967

Int[((a_) + (b_.)*sin[(e_.) + (f_.)*(x_)])^(m_.)*((A_.) + (B_.)*sin[(e_.) + (f_.)*(x_)])*((c_) + (d_.)*sin[(e_
.) + (f_.)*(x_)])^(n_.), x_Symbol] :> Dist[a^m*c^m, Int[Cos[e + f*x]^(2*m)*(c + d*Sin[e + f*x])^(n - m)*(A + B
*Sin[e + f*x]), x], x] /; FreeQ[{a, b, c, d, e, f, A, B, n}, x] && EqQ[b*c + a*d, 0] && EqQ[a^2 - b^2, 0] && I
ntegerQ[m] &&  !(IntegerQ[n] && ((LtQ[m, 0] && GtQ[n, 0]) || LtQ[0, n, m] || LtQ[m, n, 0]))

Rule 2856

Int[(cos[(e_.) + (f_.)*(x_)]*(g_.))^(p_)*((a_) + (b_.)*sin[(e_.) + (f_.)*(x_)])^(m_.)*((c_.) + (d_.)*sin[(e_.)
 + (f_.)*(x_)]), x_Symbol] :> -Simp[(d*(g*Cos[e + f*x])^(p + 1)*(a + b*Sin[e + f*x])^m)/(f*g*(m + p + 1)), x]
+ Dist[(a*d*m + b*c*(m + p + 1))/(b*(m + p + 1)), Int[(g*Cos[e + f*x])^p*(a + b*Sin[e + f*x])^m, x], x] /; Fre
eQ[{a, b, c, d, e, f, g, m, p}, x] && EqQ[a^2 - b^2, 0] && IGtQ[Simplify[(2*m + p + 1)/2], 0] && NeQ[m + p + 1
, 0]

Rule 2674

Int[(cos[(e_.) + (f_.)*(x_)]*(g_.))^(p_)*((a_) + (b_.)*sin[(e_.) + (f_.)*(x_)])^(m_), x_Symbol] :> -Simp[(b*(g
*Cos[e + f*x])^(p + 1)*(a + b*Sin[e + f*x])^(m - 1))/(f*g*(m + p)), x] + Dist[(a*(2*m + p - 1))/(m + p), Int[(
g*Cos[e + f*x])^p*(a + b*Sin[e + f*x])^(m - 1), x], x] /; FreeQ[{a, b, e, f, g, m, p}, x] && EqQ[a^2 - b^2, 0]
 && IGtQ[Simplify[(2*m + p - 1)/2], 0] && NeQ[m + p, 0]

Rule 2673

Int[(cos[(e_.) + (f_.)*(x_)]*(g_.))^(p_)*((a_) + (b_.)*sin[(e_.) + (f_.)*(x_)])^(m_), x_Symbol] :> Simp[(b*(g*
Cos[e + f*x])^(p + 1)*(a + b*Sin[e + f*x])^(m - 1))/(f*g*(m - 1)), x] /; FreeQ[{a, b, e, f, g, m, p}, x] && Eq
Q[a^2 - b^2, 0] && EqQ[2*m + p - 1, 0] && NeQ[m, 1]

Rubi steps

\begin{align*} \int (a+a \sin (e+f x))^2 (A+B \sin (e+f x)) (c-c \sin (e+f x))^{3/2} \, dx &=\left (a^2 c^2\right ) \int \frac{\cos ^4(e+f x) (A+B \sin (e+f x))}{\sqrt{c-c \sin (e+f x)}} \, dx\\ &=-\frac{2 a^2 B c^2 \cos ^5(e+f x)}{9 f \sqrt{c-c \sin (e+f x)}}+\frac{1}{9} \left (a^2 (9 A+B) c^2\right ) \int \frac{\cos ^4(e+f x)}{\sqrt{c-c \sin (e+f x)}} \, dx\\ &=\frac{2 a^2 (9 A+B) c^3 \cos ^5(e+f x)}{63 f (c-c \sin (e+f x))^{3/2}}-\frac{2 a^2 B c^2 \cos ^5(e+f x)}{9 f \sqrt{c-c \sin (e+f x)}}+\frac{1}{63} \left (4 a^2 (9 A+B) c^3\right ) \int \frac{\cos ^4(e+f x)}{(c-c \sin (e+f x))^{3/2}} \, dx\\ &=\frac{8 a^2 (9 A+B) c^4 \cos ^5(e+f x)}{315 f (c-c \sin (e+f x))^{5/2}}+\frac{2 a^2 (9 A+B) c^3 \cos ^5(e+f x)}{63 f (c-c \sin (e+f x))^{3/2}}-\frac{2 a^2 B c^2 \cos ^5(e+f x)}{9 f \sqrt{c-c \sin (e+f x)}}\\ \end{align*}

Mathematica [A]  time = 4.64179, size = 106, normalized size = 0.88 \[ \frac{a^2 c \sqrt{c-c \sin (e+f x)} \left (\sin \left (\frac{1}{2} (e+f x)\right )+\cos \left (\frac{1}{2} (e+f x)\right )\right )^5 ((130 B-90 A) \sin (e+f x)+162 A+35 B \cos (2 (e+f x))-87 B)}{315 f \left (\cos \left (\frac{1}{2} (e+f x)\right )-\sin \left (\frac{1}{2} (e+f x)\right )\right )} \]

Antiderivative was successfully verified.

[In]

Integrate[(a + a*Sin[e + f*x])^2*(A + B*Sin[e + f*x])*(c - c*Sin[e + f*x])^(3/2),x]

[Out]

(a^2*c*(Cos[(e + f*x)/2] + Sin[(e + f*x)/2])^5*(162*A - 87*B + 35*B*Cos[2*(e + f*x)] + (-90*A + 130*B)*Sin[e +
 f*x])*Sqrt[c - c*Sin[e + f*x]])/(315*f*(Cos[(e + f*x)/2] - Sin[(e + f*x)/2]))

________________________________________________________________________________________

Maple [A]  time = 1.133, size = 83, normalized size = 0.7 \begin{align*}{\frac{ \left ( -2+2\,\sin \left ( fx+e \right ) \right ){c}^{2} \left ( 1+\sin \left ( fx+e \right ) \right ) ^{3}{a}^{2} \left ( \sin \left ( fx+e \right ) \left ( 45\,A-65\,B \right ) -35\,B \left ( \cos \left ( fx+e \right ) \right ) ^{2}-81\,A+61\,B \right ) }{315\,f\cos \left ( fx+e \right ) }{\frac{1}{\sqrt{c-c\sin \left ( fx+e \right ) }}}} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

int((a+a*sin(f*x+e))^2*(A+B*sin(f*x+e))*(c-c*sin(f*x+e))^(3/2),x)

[Out]

2/315*(-1+sin(f*x+e))*c^2*(1+sin(f*x+e))^3*a^2*(sin(f*x+e)*(45*A-65*B)-35*B*cos(f*x+e)^2-81*A+61*B)/cos(f*x+e)
/(c-c*sin(f*x+e))^(1/2)/f

________________________________________________________________________________________

Maxima [F]  time = 0., size = 0, normalized size = 0. \begin{align*} \int{\left (B \sin \left (f x + e\right ) + A\right )}{\left (a \sin \left (f x + e\right ) + a\right )}^{2}{\left (-c \sin \left (f x + e\right ) + c\right )}^{\frac{3}{2}}\,{d x} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((a+a*sin(f*x+e))^2*(A+B*sin(f*x+e))*(c-c*sin(f*x+e))^(3/2),x, algorithm="maxima")

[Out]

integrate((B*sin(f*x + e) + A)*(a*sin(f*x + e) + a)^2*(-c*sin(f*x + e) + c)^(3/2), x)

________________________________________________________________________________________

Fricas [B]  time = 1.43657, size = 575, normalized size = 4.79 \begin{align*} -\frac{2 \,{\left (35 \, B a^{2} c \cos \left (f x + e\right )^{5} + 5 \,{\left (9 \, A + 8 \, B\right )} a^{2} c \cos \left (f x + e\right )^{4} -{\left (9 \, A + B\right )} a^{2} c \cos \left (f x + e\right )^{3} + 2 \,{\left (9 \, A + B\right )} a^{2} c \cos \left (f x + e\right )^{2} - 8 \,{\left (9 \, A + B\right )} a^{2} c \cos \left (f x + e\right ) - 16 \,{\left (9 \, A + B\right )} a^{2} c +{\left (35 \, B a^{2} c \cos \left (f x + e\right )^{4} - 5 \,{\left (9 \, A + B\right )} a^{2} c \cos \left (f x + e\right )^{3} - 6 \,{\left (9 \, A + B\right )} a^{2} c \cos \left (f x + e\right )^{2} - 8 \,{\left (9 \, A + B\right )} a^{2} c \cos \left (f x + e\right ) - 16 \,{\left (9 \, A + B\right )} a^{2} c\right )} \sin \left (f x + e\right )\right )} \sqrt{-c \sin \left (f x + e\right ) + c}}{315 \,{\left (f \cos \left (f x + e\right ) - f \sin \left (f x + e\right ) + f\right )}} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((a+a*sin(f*x+e))^2*(A+B*sin(f*x+e))*(c-c*sin(f*x+e))^(3/2),x, algorithm="fricas")

[Out]

-2/315*(35*B*a^2*c*cos(f*x + e)^5 + 5*(9*A + 8*B)*a^2*c*cos(f*x + e)^4 - (9*A + B)*a^2*c*cos(f*x + e)^3 + 2*(9
*A + B)*a^2*c*cos(f*x + e)^2 - 8*(9*A + B)*a^2*c*cos(f*x + e) - 16*(9*A + B)*a^2*c + (35*B*a^2*c*cos(f*x + e)^
4 - 5*(9*A + B)*a^2*c*cos(f*x + e)^3 - 6*(9*A + B)*a^2*c*cos(f*x + e)^2 - 8*(9*A + B)*a^2*c*cos(f*x + e) - 16*
(9*A + B)*a^2*c)*sin(f*x + e))*sqrt(-c*sin(f*x + e) + c)/(f*cos(f*x + e) - f*sin(f*x + e) + f)

________________________________________________________________________________________

Sympy [F(-1)]  time = 0., size = 0, normalized size = 0. \begin{align*} \text{Timed out} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((a+a*sin(f*x+e))**2*(A+B*sin(f*x+e))*(c-c*sin(f*x+e))**(3/2),x)

[Out]

Timed out

________________________________________________________________________________________

Giac [F]  time = 0., size = 0, normalized size = 0. \begin{align*} \int{\left (B \sin \left (f x + e\right ) + A\right )}{\left (a \sin \left (f x + e\right ) + a\right )}^{2}{\left (-c \sin \left (f x + e\right ) + c\right )}^{\frac{3}{2}}\,{d x} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((a+a*sin(f*x+e))^2*(A+B*sin(f*x+e))*(c-c*sin(f*x+e))^(3/2),x, algorithm="giac")

[Out]

integrate((B*sin(f*x + e) + A)*(a*sin(f*x + e) + a)^2*(-c*sin(f*x + e) + c)^(3/2), x)